package com.sl.au.repository;

import java.util.List;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Query;

import com.sl.au.entity.GridAreaDetailInfo;

public interface GridAreaDetailInfoRepository extends JpaRepository<GridAreaDetailInfo, String> {

	@Query("select g from GridAreaDetailInfo g where g.gridInfo.id=?1")
	List<GridAreaDetailInfo> findByGridId(String id);
	
	@Query("select a from GridAreaDetailInfo a where a.gridInfo is not null order by a.gridInfo,a.longlatOrder asc")
	List<GridAreaDetailInfo> findAllOrderByGridAreaInfo();
}
